//
//  AlibabaModule.h
//  lovebaby
//
//  Created by 陈星华 on 2020/3/15.
//  Copyright © 2020年 Facebook. All rights reserved.
//

#import <AlibcTradeSDK/AlibcTradeSDK.h>
#import <AlibabaAuthSDK/ALBBSDK.h>
#import <React/RCTLog.h>
#import <React/RCTConvert.h>
#import <React/RCTBridgeModule.h>
#import <UIKit/UIKit.h>

@interface AlibabaModule : NSObject
  + (instancetype)sharedInstance;
  - (void)asyncInit: (RCTResponseSenderBlock)callback;   //初始化
  - (void)showLogin: (RCTResponseSenderBlock)callback;   //登陆
  - (void)isLogin: (RCTResponseSenderBlock)callback;     //是否已经登陆
  - (void)getUserInfo: (RCTResponseSenderBlock)callback; //获取用户数据
  - (void)logout: (RCTResponseSenderBlock)callback;      //退出登陆
  - (void)showPage: (NSDictionary *)param callback: (RCTResponseSenderBlock)callback; //显示

  - (void)openByBizCode:(id<AlibcTradePage>)page param:(NSDictionary *)param callback: (RCTResponseSenderBlock)callback;
  - (void)openByUrl:(NSDictionary *)param url:(NSString *)url callback: (RCTResponseSenderBlock)callback;
  - (AlibcTradeShowParams *)dealShowParam:(NSDictionary *)param;
  - (AlibcTradeTaokeParams *)dealTaokeParams:(NSDictionary *)param;

  - (NSDictionary *)dealExParams:(NSDictionary *)param;
  
@end
